Systems and methods for synchronization of wireless devices in a peer-to-peer network

ABSTRACT

Methods, devices, and computer program products for synchronization of wireless devices in a peer-to-peer network are described herein. In one aspect, a method for synchronizing a wireless communication apparatus is provided. The method includes determining, at a wireless communication apparatus, a first time interval since transmitting a message including a time value of a clock signal of the wireless communication apparatus; and determining, at the wireless communication apparatus, a second time interval since updating the time value of the wireless communication apparatus; and transmitting a message comprising content that is based on comparing the first time interval to a first threshold and comparing the second time interval to a second threshold.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a divisional application of U.S. patent applicationSer. No. 14/024,461, filed Sep. 11, 2013, and entitled “SYSTEMS ANDMETHODS FOR SYNCHRONIZATION OF WIRLESS DEVICES IN A PEER-TO-PEERNETWORK,” which claimed priority under 35 U.S.C. §119 to ProvisionalApplication No. 61/718,882 entitled “SYSTEMS AND METHODS FORSYNCHRONIZATION OF WIRELESS DEVICES IN A PEER-TO-PEER NETWORK” filedOct. 26, 2012, and to Provisional Application No. 61/723,277 entitled“SYSTEMS AND METHODS FOR SYNCHRONIZATION OF WIRELESS DEVICES IN APEER-TO-PEER NETWORK” filed Nov. 6, 2012. Each of these priorapplications are assigned to the assignee hereof. Additionally, thedisclosures of each of these prior applications are considered part ofthis application, and are hereby expressly incorporated by reference intheir entirety.

BACKGROUND

1. Field

The present application relates generally to wireless communications,and more specifically to systems, methods, and devices forsynchronization of wireless devices in a peer-to-peer wireless network.

2. Background

In many telecommunication systems, communications networks are used toexchange messages among several interacting spatially-separated devices.Networks may be classified according to geographic scope, which couldbe, for example, a metropolitan area, a local area, or a personal area.Such networks would be designated respectively as a wide area network(WAN), metropolitan area network (MAN), local area network (LAN),wireless local area network (WLAN), or personal area network (PAN).Networks also differ according to the switching/routing technique usedto interconnect the various network nodes and devices (e.g. circuitswitching vs. packet switching), the type of physical media employed fortransmission (e.g. wired vs. wireless), and the set of communicationprotocols used (e.g. Internet protocol suite, SONET (Synchronous OpticalNetworking), Ethernet, etc.).

Wireless networks are often preferred when the network elements aremobile and thus have dynamic connectivity needs, or if the networkarchitecture is formed in an ad hoc, rather than fixed, topology.Wireless networks employ intangible physical media in an unguidedpropagation mode using electromagnetic waves in the radio, microwave,infra-red, optical, etc. frequency bands. Wireless networksadvantageously facilitate user mobility and rapid field deployment whencompared to fixed wired networks.

Devices in a wireless network may transmit and/or receive information toand from each other. To carry out various communications, the devicesmay need to coordinate according to a protocol. As such, devices mayexchange information to coordinate their activities. Improved systems,methods, and devices for coordinating transmitting and sendingcommunications within a wireless network are desired.

SUMMARY

The systems, methods, devices, and computer program products discussedherein each have several aspects, no single one of which is solelyresponsible for its desirable attributes. Without limiting the scope ofthis invention as expressed by the claims which follow, some featuresare discussed briefly below. After considering this discussion, andparticularly after reading the section entitled “Detailed Description,”it will be understood how advantageous features of this inventioninclude reduced power consumption when introducing devices on a medium.

One aspect of the disclosure provides a method for synchronizing awireless communication apparatus. The method includes receiving, at thewireless communication apparatus, one or more messages including one ormore received time values. The method further includes updating a timevalue of a clock signal of the wireless communication apparatus to avalue derived from the received time values in response to determiningthat a magnitude of a difference between the time value and the derivedtime value is greater than a threshold.

Another aspect of the disclosure provides a method of wirelesscommunication. The method includes determining, at a wirelesscommunication apparatus, a first time interval since transmitting amessage including a time value of a clock signal of the wirelesscommunication apparatus. The method further includes determining, at thewireless communication apparatus, a second time interval since updatingthe time value of the wireless communication apparatus. The methodfurther includes transmitting a message comprising content that is basedon comparing the first time interval to a first threshold and comparingthe second time interval to a second threshold.

Another aspect of the disclosure provides a method for synchronizing awireless communication apparatus. The method includes selectivelypreparing a synchronization message for transmission during a discoverytime interval of a discovery time period based on a probability valuecorresponding to a frequency for preparing the synchronization messageover a plurality of discovery time periods. The synchronization messageincludes a first timestamp of the wireless communication apparatus. Themethod further includes initiating a contention based process fortransmitting the synchronization message in response to preparing thesynchronization message. The method further includes selectivelyupdating a time value of the wireless communication apparatus inresponse to receiving one or more received synchronization messages fromother wireless communication apparatuses during the discovery interval.The one or more received synchronization messages include one or morereceived timestamps of the other wireless communication apparatuses.Updating the time value including updating based on one or more criteriaand the received timestamps. The method further includes transmittingthe synchronization message in response to determining an absence anyreceived synchronization messages during the discovery interval.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1A illustrates an example of a wireless communication system inwhich aspects of the present disclosure may be employed.

FIG. 1B illustrates another example of a wireless communication systemin which aspects of the present disclosure may be employed.

FIG. 2 illustrates a functional block diagram of a wireless device thatmay be employed within the wireless communication system of FIG. 1.

FIG. 3A illustrates an exemplary communication timeline in a wirelesscommunication system in accordance with aspects of the presentdisclosure.

FIG. 3B is a flowchart of an exemplary process of discovering devices ina wireless communication system in accordance with aspects of thepresent disclosure.

FIG. 3C is a flowchart of an exemplary process of querying devices in awireless communication system in accordance with aspects of the presentdisclosure.

FIG. 4A illustrates a message that may include a time value forsynchronization.

FIG. 4B is a flowchart of a method for transmitting and receiving asynchronization frame in accordance with an embodiment.

FIG. 4C is a flowchart of a method for synchronization that is based ona received signal strength indication.

FIG. 5 is a flowchart of a method of synchronizing a wirelesscommunications apparatus, in accordance with an embodiment.

FIG. 6 is a functional block diagram of an exemplary wirelesscommunication apparatus that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B.

FIG. 7 is a flowchart of another method of synchronizing a wirelesscommunications apparatus, in accordance with an embodiment.

FIG. 8 is a functional block diagram of an exemplary wirelesscommunication apparatus that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B.

FIG. 9 is a flowchart of another method of synchronizing a wirelesscommunications apparatus, in accordance with an embodiment.

FIG. 10 is a flowchart of another method of synchronizing a wirelesscommunications apparatus, in accordance with an embodiment.

FIG. 11 is a functional block diagram of an exemplary wirelesscommunication apparatus that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B.

FIG. 12 is a flowchart of another method of synchronizing a wirelesscommunications apparatus, in accordance with an embodiment.

FIG. 13 illustrates a message that may include a time value forsynchronization.

FIG. 14 is a functional block diagram of an exemplary wirelesscommunication apparatus that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B.

FIG. 15 is a plot showing exemplary values for how much time may beneeded to join a NAN network based on different sync frameprobabilities.

DETAILED DESCRIPTION

The word “exemplary” is used herein to mean “serving as an example,instance, or illustration.” Any embodiment described herein as“exemplary” is not necessarily to be construed as preferred oradvantageous over other embodiments. Various aspects of the novelsystems, apparatuses, and methods are described more fully hereinafterwith reference to the accompanying drawings. This disclosure may,however, be embodied in many different forms and should not be construedas limited to any specific structure or function presented throughoutthis disclosure. Rather, these aspects are provided so that thisdisclosure will be thorough and complete, and will fully convey thescope of the disclosure to those skilled in the art. Based on theteachings herein one skilled in the art should appreciate that the scopeof the disclosure is intended to cover any aspect of the novel systems,apparatuses, and methods disclosed herein, whether implementedindependently of, or combined with, any other aspect of the invention.For example, an apparatus may be implemented or a method may bepracticed using any number of the aspects set forth herein. In addition,the scope of the invention is intended to cover such an apparatus ormethod which is practiced using other structure, functionality, orstructure and functionality in addition to or other than the variousaspects of the invention set forth herein. It should be understood thatany aspect disclosed herein may be embodied by one or more elements of aclaim.

Although particular aspects are described herein, many variations andpermutations of these aspects fall within the scope of the disclosure.Although some benefits and advantages of the preferred aspects arementioned, the scope of the disclosure is not intended to be limited toparticular benefits, uses, or objectives. Rather, aspects of thedisclosure are intended to be broadly applicable to different wirelesstechnologies, system configurations, networks, and transmissionprotocols, some of which are illustrated by way of example in thefigures and in the following description of the preferred aspects. Thedetailed description and drawings are merely illustrative of thedisclosure rather than limiting, the scope of the disclosure beingdefined by the appended claims and equivalents thereof.

Wireless network technologies may include various types of wirelesslocal area networks (WLANs). A WLAN may be used to interconnect nearbydevices together, employing widely used networking protocols. However,the various aspects described herein may apply to any communicationstandard, such as a wireless protocol.

In some implementations, a WLAN includes various devices which are thecomponents that access the wireless network. For example, there may betwo types of devices: access points (“APs”) and clients (also referredto as stations, or “STAs”). In general, an AP may serve as a hub or basestation for the WLAN and a STA serves as a user of the WLAN. Forexample, a STA may be a laptop computer, a personal digital assistant(PDA), a mobile phone, etc. In an example, a STA connects to an AP via aWiFi (e.g., IEEE 802.11 protocol) compliant wireless link to obtaingeneral connectivity to the Internet or to other wide area networks. Insome implementations a STA may also be used as an AP.

An access point (“AP”) may also comprise, be implemented as, or known asa NodeB, Radio Network Controller (“RNC”), eNodeB, Base StationController (“BSC”), Base Transceiver Station (“BTS”), Base Station(“BS”), Transceiver Function (“TF”), Radio Router, Radio Transceiver, orsome other terminology.

A station “STA” may also comprise, be implemented as, or known as anaccess terminal (“AT”), a subscriber station, a subscriber unit, amobile station, a remote station, a remote terminal, a user terminal, auser agent, a user device, user equipment, or some other terminology. Insome implementations an access terminal may comprise a cellulartelephone, a cordless telephone, a Session Initiation Protocol (“SIP”)phone, a wireless local loop (“WLL”) station, a personal digitalassistant (“PDA”), a handheld device having wireless connectioncapability, or some other suitable processing device or wireless deviceconnected to a wireless modem. Accordingly, one or more aspects taughtherein may be incorporated into a phone (e.g., a cellular phone orsmartphone), a computer (e.g., a laptop), a portable communicationdevice, a headset, a portable computing device (e.g., a personal dataassistant), an entertainment device (e.g., a music or video device, or asatellite radio), a gaming device or system, a global positioning systemdevice, or any other suitable device that is configured to communicatevia a wireless medium.

FIG. 1A illustrates an example of a wireless communication system 100 inwhich aspects of the present disclosure may be employed. The wirelesscommunication system 100 may operate pursuant to a wireless standard,such as an 802.11 standard. The wireless communication system 100 mayinclude an AP 104, which communicates with STAs. In some aspects, thewireless communication system 100 may include more than one AP.Additionally, the STAs may communicate with other STAs. As an example, afirst STA 106 a may communicate with a second STA 106 b. As anotherexample, a first STA 106 a may communicate with a third STA 106 calthough this communication link is not illustrated in FIG. 1A.

A variety of processes and methods may be used for transmissions in thewireless communication system 100 between the AP 104 and the STAs andbetween an individual STA, such as the first STA 106 a, and anotherindividual STA, such as the second STA 106 b. For example, signals maybe sent and received in accordance with OFDM/OFDMA techniques. If thisis the case, the wireless communication system 100 may be referred to asan OFDM/OFDMA system. Alternatively, signals may be sent and receivedbetween the AP 104 and the STAs and between an individual STA, such asthe first STA 106 a, and another individual STA, such as the second STA106 b, in accordance with CDMA techniques. If this is the case, thewireless communication system 100 may be referred to as a CDMA system.

A communication link that facilitates transmission from the AP 104 toone or more of the STAs may be referred to as a downlink (DL) 108, and acommunication link that facilitates transmission from one or more of theSTAs to the AP 104 may be referred to as an uplink (UL) 110.Alternatively, a downlink 108 may be referred to as a forward link or aforward channel, and an uplink 110 may be referred to as a reverse linkor a reverse channel.

A communication link may be established between STAs. Some possiblecommunication links between STAs are illustrated in FIG. 1A. As anexample, a communication link 112 may facilitate transmission from thefirst STA 106 a to the second STA 106 b. Another communication link 114may facilitate transmission from the second STA 106 b to the first STA106 a.

The AP 104 may act as a base station and provide wireless communicationcoverage in a basic service area (BSA) 102. The AP 104 along with theSTAs associated with the AP 104 and that use the AP 104 forcommunication may be referred to as a basic service set (BSS).

It should be noted that the wireless communication system 100 may nothave a central AP 104, but rather may function as a peer-to-peer networkbetween the STAs. Accordingly, the functions of the AP 104 describedherein may alternatively be performed by one or more of the STAs.

FIG. 1B illustrates an example of a wireless communication system 100that may function as a peer-to-peer network, in which aspects of thepresent disclosure may be employed. For example, the wirelesscommunication system 100 shown in FIG. 1B shows STAs, 106 b, 106 c, 106d, and 106 e that may communicate with each other without the presenceof an AP. As such, the STAs, 106 b, 106 c, 106 d, and 106 e may beconfigured to communicate in different ways to coordinate transmissionand reception of messages to prevent interference and accomplish varioustasks. In one aspect, the network shown in FIG. 1A or 1B may configuredas a “near-me are network” (NAN). In one aspect, a NAN may refer to anetwork for communication between STAs that are located in closeproximity to each other. In some cases the STAs operating within the NANmay belong to different network structures (e.g., STAs in differenthomes or buildings as part of independent LANs with different externalnetwork connections).

FIG. 2 illustrates various components that may be utilized in a wirelessdevice 202 that may be employed within the wireless communication system100. The wireless device 202 is an example of a device that may beconfigured to implement the various methods described herein. Forexample, the wireless device 202 may comprise the AP 104 or one of theSTAs.

The wireless device 202 may include a processor 204 which controlsoperation of the wireless device 202. The processor 204 may also bereferred to as a central processing unit (CPU). Memory 206, which mayinclude both read-only memory (ROM) and random access memory (RAM), mayprovide instructions and data to the processor 204. A portion of thememory 206 may also include non-volatile random access memory (NVRAM).The processor 204 typically performs logical and arithmetic operationsbased on program instructions stored within the memory 206. Theinstructions in the memory 206 may be executable to implement themethods described herein.

The processor 204 may comprise or be a component of a processing systemimplemented with one or more processors. The one or more processors maybe implemented with any combination of general-purpose microprocessors,microcontrollers, digital signal processors (DSPs), field programmablegate array (FPGAs), programmable logic devices (PLDs), controllers,state machines, gated logic, discrete hardware components, dedicatedhardware finite state machines, or any other suitable entities that canperform calculations or other manipulations of information.

The processing system may also include machine-readable media forstoring software. Software shall be construed broadly to mean any typeof instructions, whether referred to as software, firmware, middleware,microcode, hardware description language, or otherwise. Instructions mayinclude code (e.g., in source code format, binary code format,executable code format, or any other suitable format of code). Theinstructions, when executed by the one or more processors, cause theprocessing system to perform the various functions described herein. Inaddition, the wireless device 202 may include a clock 224 configured togenerate a clock signal that is used to coordinate and synchronizeactivities of the wireless device 202. In some configurations, theprocessor 204 may include the clock 224. The processor 204 may beconfigured to update the clock with a time value to allow forsynchronization with other wireless devices.

The wireless device 202 may also include a housing 208 that may includea transmitter 210 and/or a receiver 212 to allow transmission andreception of data between the wireless device 202 and a remote location.The transmitter 210 and receiver 212 may be combined into a transceiver214. An antenna 216 may be attached to the housing 208 and electricallycoupled to the transceiver 214. The wireless device 202 may also include(not shown) multiple transmitters, multiple receivers, multipletransceivers, and/or multiple antennas.

The transmitter 210 may be configured to wirelessly transmit packetshaving different packet types or functions. For example, the transmitter210 may be configured to transmit packets of different types generatedby the processor 204. When the wireless device 202 is implemented orused as an AP 104 or STA 106, the processor 204 may be configured toprocess packets of a plurality of different packet types. For example,the processor 204 may be configured to determine the type of packet andto process the packet and/or fields of the packet accordingly. When thewireless device 202 is implemented or used as an AP 104, the processor204 may also be configured to select and generate one of a plurality ofpacket types. For example, the processor 204 may be configured togenerate a discovery packet comprising a discovery message and todetermine what type of packet information to use in a particularinstance.

The receiver 212 may be configured to wirelessly receive packets havingdifferent packet types. In some aspects, the receiver 212 may beconfigured to detect a type of a packet used and to process the packetaccordingly.

The wireless device 202 may also include a signal detector 218 that maybe used in an effort to detect and quantify the level of signalsreceived by the transceiver 214. The signal detector 218 may detect suchsignals as total energy, energy per subcarrier per symbol, powerspectral density and other signals. The wireless device 202 may alsoinclude a digital signal processor (DSP) 220 for use in processingsignals. The DSP 220 may be configured to generate a packet fortransmission. In some aspects, the packet may comprise a physical layerdata unit (PPDU).

The wireless device 202 may further comprise a user interface 222 insome aspects. The user interface 222 may comprise a keypad, amicrophone, a speaker, and/or a display. The user interface 222 mayinclude any element or component that conveys information to a user ofthe wireless device 202 and/or receives input from the user.

The various components of the wireless device 202 may be coupledtogether by a bus system 226. The bus system 226 may include a data bus,for example, as well as a power bus, a control signal bus, and a statussignal bus in addition to the data bus. The components of the wirelessdevice 202 may be coupled together or accept or provide inputs to eachother using some other mechanism.

Although a number of separate components are illustrated in FIG. 2, oneor more of the components may be combined or commonly implemented. Forexample, the processor 204 may be used to implement not only thefunctionality described above with respect to the processor 204, butalso to implement the functionality described above with respect to thesignal detector 218 and/or the DSP 220. Further, each of the componentsillustrated in FIG. 2 may be implemented using a plurality of separateelements.

Devices, such as a group of STAs, 106 b, 106 c, 106 d, and 106 e shownin FIG. 1B, for example, may be used for neighborhood aware networking,or social-WiFi networking. For example, various stations within thenetwork may communicate on a device to device (e.g., peer-to-peercommunications) basis with one another regarding applications that eachof the stations supports. A discovery protocol may be used in asocial-WiFi network to enable STAs to advertise themselves (e.g., bysending discovery packets) as well as discover services provided byother STAs (e.g., by sending paging or query packets), while ensuringsecure communication and low power consumption. Furthermore, at least aportion of the discovery protocol may be related to coordinating and/orsynchronizing activities of the STAs. It should be noted that adiscovery packet may also be referred to as a discovery message or adiscovery frame. It should also be noted that a paging or query packetmay also be referred to as a paging or query message or a paging orquery frame.

Furthermore, to ensure proper communication between multiple STAs, STAsmay require information regarding characteristics of other STAs. Forexample, the STA 106 may require timing information about the AP 104 inorder to synchronize timing of communication between the STA 106 and theAP 104. Additionally or alternatively, the STA 106 may require otherinformation such as a medium access control (MAC) address of the AP 104or another STA, an identifier of the basic service set (BSS) served bythe AP 104, etc. The STA 106 may determine whether it needs suchinformation independently, such as through software that is executedusing memory 206 and processor 204.

The AP 104 or STA 106 may have a plurality of operational modes. Forexample, the STA 106 may have a first operational mode referred to as anactive mode, normal operation mode, or full power mode. In the activemode, the STA 106 may always be in an “awake” state and activelytransmit/receive data with another STA 106. Further, the STA 106 mayhave a second operational mode referred to as a power-save mode or sleepmode. In the power-save mode, the STA 106 may be in the “awake” state ormay be in a “doze” or “sleep” state where the STA 106 does not activelytransmit/receive data with another STA 106. For example, the receiver212 and possibly DSP 220 and signal detector 218 of the STA 106 mayoperate using reduced power consumption in the doze state. Further, inthe power-save mode, a STA 106 may occasionally enter the awake state tolisten to messages from an AP 104 or from other STAs (e.g., pagingmessages) that indicate to the STA 106 whether or not the STA 106 needsto “wake up” (e.g., enter the awake state) at a certain time so as to beable to transmit/receive data with the AP 104 or another STA.

FIG. 3A illustrates an exemplary communication timeline 300 a in awireless communication system where STAs may communicate via onechannel. In one aspect, the communication according to the timelineshown in FIG. 3A may be used in a peer-to-peer wireless network, such asthe network shown in FIG. 1B. The exemplary communication timeline 300 amay include a discovery interval (DI) 302 a of a time duration AA 306 a,a paging interval (PI) 304 a of a time duration ΔB 308 a, and an overallinterval of a time duration ΔC 310 a. In some aspects, communicationsmay occur via other channels as well. Time increases horizontally acrossthe page over the time axis.

During the DI 302 a, APs or STAs may advertise services throughbroadcast messages such as discovery packets. APs or STAs may listen tobroadcast messages transmitted by other APs or STAs. In some aspects,the duration of DIs may vary over time. In other aspects, the durationof the DI may remain fixed over a period of time. The end of the DI 302a may be separated from the beginning of the subsequent PI 304 a by afirst remainder period of time as illustrated in FIG. 3 a. The end ofthe PI 304 a may be separated from the beginning of a subsequent DI by adifferent remainder period of time as illustrated in FIG. 3A. However,different combinations of remainder time periods are contemplated.

During the PI 304 a, APs or STAs may indicate interest in one or more ofa plurality of services advertised in a broadcast message bytransmitting paging request messages such as paging request packets. APsor STAs may listen to paging request messages transmitted by other APsor STAs. In some aspects, the duration of the PI may vary over time. Inother aspects, the duration of the PI may remain constant over a periodof time. In some aspects, the duration of the PI may be less than theduration of the DI.

The overall interval of duration ΔC 310 a may measure the period of timefrom the beginning of one DI to the beginning of a subsequent DI asillustrated in FIG. 3 a. In some aspects, the duration of the overallinterval may vary over time. In other aspects, the duration of theoverall interval may remain constant over a period of time. At theconclusion of the overall interval of duration ΔC 310 a, another overallinterval may begin, including a DI, a PI, and the remainder intervals.Consecutive overall intervals may follow indefinitely or continue for afixed period of time.

A STA may enter a sleep or power-save mode when the STA is nottransmitting or listening or is not expecting to transmit or listen. Asan example, the STA may sleep during periods other than the DI or PI.The STA in the sleep mode or power-save mode may awake or return tonormal operation or full power mode at the beginning of the DI or PI toenable transmission or listening by the STA. In some aspects, the STAmay awake or return to normal operation or full power mode at othertimes when the STA expects to communicate with another device, or as aresult of receiving a notification packet instructing the STA to awake.The STA may awake early to ensure that the STA receives a transmission.

As described above, during the DI, APs or STAs may transmit discoverypackets (DPs). During the PI, APs or STAs may transmit paging requestpackets (PRs). A DP may be a packet configured to advertise a pluralityof services provided by a STA or AP and to indicate when the paginginterval is for the device that transmits the discovery packet. The DPmay include a data frame, management frame, or management action frame.The DP may carry information generated by a higher layer discoveryprotocol or an application based discovery protocol. The PR may be apacket configured to indicate interest in at least one of the pluralityof services provided by an AP or STA.

The start and end of the DI and PI may be known via numerous methods toeach STA desiring to transmit a discovery packet or a paging requestpacket. In some aspects, each STA may synchronize its clock with theother APs or STAs and set a shared DI and PI start time and DI durationand PI duration. In other aspects, a device may send a signal such as aspecial clear to send (S-CTS) signal to clear the medium of legacycommunications, such as communications that may conflict or not becompliant with aspects of the present disclosure, and indicate thebeginning and duration of the DI or PI period, as well as additionalinformation about the DI and PI durations.

A STA potentially interested in services advertised via discoverypackets, such as from other STAs, may awaken or remain awake during theDI and process discovery packets to determine if a particular discoverypacket includes information about one or more of a plurality of servicesthat may be of interest to the receiving STA. After the DI period, STAsnot planning to communicate information may enter a sleep or power-savemode for a break period until the next time the STAs plan tocommunicate. In some aspects, a STA may enter the sleep or power-savemode until the STA may communicate additional information with anotherdevice outside of the DI or PI. In some aspects, the STA may enter thesleep or power-save mode until the beginning of the next PI. At thebeginning of the PI, the interested STA may awake to transmit a pagingrequest packet to the provider of the service.

A STA waiting for a response to a transmitted discovery packet, such asdiscovery packets transmitted to other STAs, may awaken or remain awakeduring the PI and process paging request packets to determine if aparticular paging request packet indicates interest by another device inat least one of plurality of services provided by the STA. After the PIperiod, STAs not planning to communicate information may enter a sleepor power-save mode for a break period until the next time the STAs planto communicate. In some aspects, a STA may enter the sleep or power-savemode until the STA may communicate additional information with anotherdevice outside of the DI or PI. In some aspects, the STA may enter thesleep or power-save mode until the beginning of the next DI.

As examples, the duration ΔC of the overall interval may beapproximately one to five seconds. In other aspects, the overallinterval may be less than one second or more than five seconds. Theduration ΔA of the DI may equal approximately 16 milliseconds in someaspects while more or less than 16 milliseconds in other aspects. Theduration ΔB of the PI may equal approximately the duration ΔA in someaspects. In other aspects, the duration ΔB may be more or less than theduration ΔA.

FIG. 3B is a flowchart of an exemplary process 300 b of discoveringdevices in a wireless communication system. The process 300 b may beused to introduce two devices, such as two STAs and 106 b. For example,a STA may advertise information about one or more of a plurality ofservices that may be of interest to various other STAs to which theinformation is directed. In some aspects, a service offered by a STA mayinclude a service offered by an application (e.g., a gaming application,a shopping application, a social networking application, etc.) that auser has downloaded or that is native to the STA. For example, a user ofthe STA may want to invite other users of the application to interactwith the user via the application. At block 302 b, the STA may initiatetransmission of announcements. Each announcement may include a discoverypacket or message including the information relating to the one or moreservices. At block 304 b, the STA may wake up from a power-save mode orsleep mode during a discovery interval to send announcements to one ormore STAs. At block 306 b, the STA may send one or more shortannouncements regarding a particular service, such as “Jack's Fruits,”in order to facilitate discovery of the STA. The short announcements mayinclude a discovery packet or message. The receiving STAs that areinterested in the one or more services advertised by the STA may respondwith a paging request (or query request) packet or message thatindicates interest in the service provided by the STA. At block 308 b,the STA may receive queries (e.g., a paging or query request) forinformation on the particular service, such as “Jack's Fruits.” Inresponse, at block 310 b, the STA may send a response to the queries.Follow on messaging between the STA and the various querying STAs mayoccur. The STA and the various STAs may enter power-save mode or sleepmode in the intervals between the exchanges of messages between theSTAs. The receiving may be performed by receiver 212 or the transceiver214, for example, and the transmitting may be performed by thetransmitter 210 or the transceiver 214, for example.

FIG. 3C is a flowchart of an exemplary process 300 c of querying devicesin a wireless communication system in accordance with aspects of thepresent disclosure. At block 302 c, a STA may input a shopping list,which may include various vendors that a user of the STA may have aninterest in. For example, a user may download a shopping list from theInternet. Although the process 300 c is described with respect to ashopping application, those having ordinary skill in the art willappreciate that the process 300 c applies to other applications, such asgaming applications, social networking applications, etc. At block 304c, the STA may set up filters for the shopping list. For example, afilter may be set up to allow the STA to wake up from a power-save modeor sleep mode only when a discovery packet or message is received forparticular vendors or applications. At block 306 c, the STA may wake upduring a discovery interval to listen to announcements. Eachannouncement may include a discovery packet or message includinginformation relating to one or more services offered by one or moreother STAs. At block 308 c, the STA may receive an announcement from asecond STA, such as a “Jack's Fruits” announcement. The STA maydetermine whether it is interested in one or more sets of informationrelated to the announcement and may respond with a paging request (orquery request) packet or message that indicates its interest in theinformation. For example, if the STA is interested in a particular saleitem offered by the second STA, the STA may respond with a pagingrequest (or query request) packet or message. At block 310 c, the STAsends a query for more information relating to the announcement, such asmore information on Jack's Fruits. At block 312 c, the STA may receive aresponse to one or more queries that the STA sent to other STAsregarding services offered by the other STAs.

It is desirable for the STAs described above (e.g., using a discoveryprotocol used in a social-WiFi network) to be able to advertisethemselves, as well as discover services provided by other STAs, using asecure communication protocol and while keeping power consumption low.For example, it is desirable for a STA to advertise its offered servicesby securely sending discovery packets or messages and for the STA todiscover services offered by other STAs by securely sending paging orquery packets or messages while avoiding excess power consumption. Forexample in accordance with certain embodiments, STAs may “sleep” amajority of a time period and wake up for short discovery intervals asdescribed to decrease power consumption. There may be certain conditionsthat allow the STAs to make use of short time intervals to decreasepower consumption while still effectively allowing discovery andadvertisement of services within the network. For example, it isdesirable that STAs that transmit during the short time intervals “know”that intended receivers are active to receive the transmitting messages.In addition, it is further desirable that STAs that are searching fordifferent services advertised by another STA 106 activate theirreceivers at the appropriate time to receive messages advertisingservices from other STAs. As such, certain embodiments described hereinare directed to synchronization between different STAs to allow forperforming device discovery as described above and for synchronizationof other communications while allowing for reduced power consumption.For example certain embodiments are directed to synchronization so thatSTAs are activated for transmitting and receiving at the same time.

Furthermore, when STAs communicate without a central coordinator, suchas an AP 104, synchronization of communications between the STAs may bedesirable. As just described, if the STAs are not synchronized, the STAsmay not receive discovery messages within the discovery interval, or beable to transmit paging requests within the correct paging interval tobe received by other STAs. Clock synchronization therefore may provide acommon reference time that may be used to determine timing ofcommunication intervals such as the discovery interval 302 a and thepaging interval 304 a. As each STA 106 operates independently of theother STAs, each generating an individual clock signal, the clocksignals of the various STAs may become out of sync with each other orwith the AP 104. For example, if a STA 106 is in a “doze” state, itsclock signal may drift and define a reference time value that is fasteror slower as compared to other clocks signals of other STAs.

Certain aspects described herein are directed to devices and methods forsynchronization of clock signals of STAs operating in a peer-to-peerfashion. In some aspects, at least some of the STAs may transmit thecurrent time value of their clock signals to the other STAs. Forexample, in accordance with certain embodiments, STAs may periodicallytransmit a ‘sync’ frame that carries a time stamp. The current timevalue may correspond to a time-stamp value. For example, in oneembodiment, a discovery message as described above may serve as the‘sync’ frame and carry a current time value of a STA 106. In addition tothe time stamp, the sync frame may also include information regardingthe discovery interval and discovery period. For example, the sync framemay include the schedule of the discovery interval and discovery period.Upon receipt of a sync frame, a STA 106 that may be new to the networkmay determine the time and the discovery interval/discovery periodschedule in the network. STAs already communicating within the networkmay maintain synchronization while overcoming clock drift as describedbelow. Based on the sync message, STAs may enter and exit a network(e.g., a NAN) without losing synchronization. Furthermore, thesynchronization messages described herein may allow for avoidingexcessive power drain and the STAs in the network may share the burdenof messaging for synchronization. Furthermore, certain embodiments allowfor a low messaging overhead (e.g., as only a few devices may send syncframes in every discovery period as will be described below).Additionally, the use of sync messages may allow each clock in thenetwork to be continuously maintained in synchronization with otherclocks in the network. As described above with reference to FIG. 3A,discovery packets within a NAN are transmitted during a discoveryinterval 302 a that occurs every discovery period. As such, syncmessages may be sent during a discovery interval 302 a for certaindiscovery periods.

It should be appreciated that a STA 106 may not transmit a sync frameevery discovery interval. Rather, a probability value (P_sync), as isfurther described below, may be used to determine whether the STA 106prepares and/or prepares a sync frame. As such, while at least some syncframes are sent for every discovery interval, not all the STAsparticipating in the NAN transmit a sync frame in every discoveryinterval. This may allow for reduced power consumption in transmittingsync frames while still enabling synchronization, compared to analternative in which each STA transmits a synchronization frame in eachdiscovery interval.

FIG. 4A illustrates a message 400 that may include a time value forsynchronization. As described above, in some embodiments, the message400 may correspond to a discovery message as described above. Themessage 400 may include a discovery packet header 408. The message mayfurther include 410 a time value for synchronization 410. In someembodiments, the time value 410 may be included in the discovery packetheader 408. The time value may correspond to a current time value of aclock signal of the STA 106 transmitting the message 400. The message400 may further include discovery packet data 412. While FIG. 4A shows adiscovery message serving as the sync message, it should be appreciatedthat according to other embodiments, the sync message may be sent apartfrom the discovery message. For example, in some aspects, the syncmessage may be a separate message or may be a part of another messageother than the discovery message.

FIG. 4B is a flowchart of a method 400 b for transmitting and receivinga synchronization frame in accordance with an embodiment. In one aspect,according to the method 400 b of FIG. 4B, sync frames are only sent by acertain number of nodes within a NAN for any one discovery period. Atdecision block 402 b, it is determined whether a sync frame is preparedfor transmission for the discovery interval using a probability valueP_sync. Stated another way, the STA 106 may determine whether to preparea sync frame for transmission based on a probability value. For example,in some cases the probability value may be on the order of 1 such thatthe STA 106 prepares the sync frame for transmission for every discoveryperiod. Alternatively, according to another embodiment, the probabilitymay be on the order of, for example, 0.3 such that the STA 106 onlyprepares a sync frame for transmission during a discovery intervalapproximately every third discovery period. This can be donepseudo-randomly such that different STAs prepare sync frames fortransmission during different discovery periods. In this way, syncframes may be transmitted in all discovery periods but not by each STAin each discovery period. In addition, the value of P_sync may bechanged or adapted during operation. For example, the value of P_syncmay be changed or adapted according to the number of STAs in thenetwork, or the number of STAs nearby to an originating STA 106. Forexample, the value of P_sync may be reduced as the number of STAs in theneighborhood of the transmitting STA 106 increases, while in a networkwith fewer STAs, it may be beneficial to use a higher P_sync value. Ifit determined at block 402 b not to prepare the sync frame, then atblock 418 b, the STA 106 may listen for time values from other STAs,such as those contained within sync frames transmitted by other STAs,and the STA may update its own time value based on received time valuesas necessary to be synchronized.

If a STA decides to prepare a sync frame based on the probabilityP_sync, then at block 404 b, a sync frame is prepared for transmission.The sync frame may include a time stamp of the STA 106 as describedabove. In addition, the sync frame may include a network identifier thatidentifiers the NAN or “social Wi-Fi” network in which the STA 106 isparticipating. For example, the unique network identifier may berandomly generated when the network is first established between theSTAs and may remain the same during the lifetime of the network. A STA106 receiving a sync frame with a network identifier may only perform anupdate of a time value based on a received time value if the networkidentifier received matches the network identifier of the network thatthe STA 106 is currently participating within. That is, a STA may decideto only update its clock based on messages received from other devicesthat are on the same network. At block 406 b, the STA 106 may begin acontention procedure for transmitting the sync frame during thediscovery interval. However, in some cases before the contentionprocedures allows for the STA 106 to transmit the sync frame, a syncframe may be received from another STA (e.g., STA 106 b) during thediscovery interval. As such, at decision block 408 b, it is determinedwhether a sync frame is received from another STA 106 b during thediscovery interval. If a sync frame was received from another STA 106 b,then at block 410 b, transmission of the sync frame by the STA 106 iscanceled. The received time stamp from STA 106 b may then be used topotentially update the time of the STA 106 according to one or morecriteria as described in the embodiments below. One potential criteriais shown in at decision block 412 b where the STA 106 determines if thereceived time stamp is greater than a current time of the STA 106. If,the received timestamp is greater than the current time stamp of the STA106, the STA 106 adopts the received time stamp for use in determiningwhen to transmit and receive as shown in block 414 b. Otherwise, thecurrent time stamp of the STA 106 is not adopted. In another embodiment,the STA 106 may update its time value to the maximum of all receivedtime stamps or otherwise provided by anyone or a combination of theembodiments described below. The timestamp of the STA 106 may not countin determining the maximum. This may ensure that a STA 106 that has afaster drift and has not transmitted its sync frame keeps its clock insync. In some embodiments, the STA 106 may update its time value to theminimum of all received time stamps. This may be done in a mannersimilar to the manner discussed below with respect to using the maximumreceived time, but may use a minimum (slowest) received time valueinstead of a maximum (fastest) received time value.

If by decision block 408 b, a sync frame is not received from anotherSTA 106 b during the discovery interval, at block 416 b, the preparedsync frame is transmitted by the STA 106.

The criteria for updating a current time value of a STA 106 based onreceived time value from another STA 106 b may further depend on thereceived signal strength indication (RSSI) of the STA 106. For example,based on the RSSI of the STA 106, even where a STA 106 receives a syncframe, it may nonetheless proceed with transmitting a sync frame it hasprepared.

For example, FIG. 4C is a flowchart of a method for synchronization thatis based on a received signal strength indication. Blocks, 402 c, 404 c,and 406 c correspond to blocks 402 b, 404 b, 406 b and 408 b of FIG. 4B.If at block 406 c it is determined that a sync frame is received fromanother STA 106 b, then the current STA 106 timestamp may be updated asshown in blocks 408 c and 410 c, or based on other criteria, asdescribed above with respect to blocks 410 b and 412 b of FIG. 4B. Inaddition, if at block 406 c it is determined that a sync frame isreceived from another STA 106 b, then at decision block 412 c is itdetermined whether an RSSI of the STA 106 is above some threshold. Thethreshold may be known previously to the STA 106 as established by apre-configured value. If the RSSI is above a threshold, then at block414 c, the sync frame transmission is canceled. However, if the RSSI ofthe STA 106 is less than the threshold as determined in decision block412 c, then the prepare sync frame is transmitted as shown in block 416c. As such, although a sync frame was received, in some cases the STA106 nonetheless transmits a prepared sync frame. If no sync frame isreceived as determined in block 406 c, then at block 416 c the syncframe is transmitted similar to that described above with reference toFIG. 4B.

It should be appreciated that the RSSI threshold described above withreference to block 412 c may be adaptive and based on differentconditions. For example, the sync frame received from the other STA 106b may include an RSSI threshold that indicates that STAs that see thesync frame at that threshold would attempt to send their own syncframes. This allows adaptation based on RSSIs of neighbors in the NAN.For example, block 412 c may determine whether the RSSI of the STA 106is greater than an RSSI threshold received from the sync frame. As afurther adaptation, in contrast to comparing the RSSI of the STA 106 tojust one received RSSI threshold, the STA 106 may compare its RSSI withRSSI threshold received in multiple sync frames from multiple differentSTAs. For example, block 412 may determine whether the RSSI of the STA106 is greater than the RSSI thresholds in all sync frames received andcancel the current sync frame transmission only if the RSSI of the STA106 is greater than all received RSSI thresholds.

The criteria for updating the current clock value based on received syncframes may be based on a variety of criteria as is further described inthe embodiments below. For example, as will be further described below,excessive drift may be detected. For example a STA 106 may filter outreceived clock values that indicate excessive drift before using thevalues obtained to update its own clock. The drift threshold for whichclocks are filtered out may be based on a pre-determined maximum allowedclock drift. In other embodiment, the threshold may be dynamicallydetermined.

In addition, a new STA 106 c that arrives into a network such as a NANmay have a timestamp that is significantly different from the currenttime used throughout the network for synchronization of, for example,discovery intervals and periods. As such, in accordance with anembodiment, a discovery packet of the new STA 106 c may include atimestamp based on a condition that if the STA 106 c has received atimestamp from another STA 106 that is already in the NAN. In oneaspect, all zeros in the time stamp field may be used as a NULLindication. In another aspect, an additional field may be included, forexample in the discovery message, that indicates that a time stamp ispresent or can be used for synchronization.

Each of the STAs may evaluate the current time values of the clocksignals received from the other STAs and adjust the time value of itsclock signal to the maximum of the time values observed if its own clockhas a lesser value. In other words, where T(X) defines the time value ofa clock signal of a STA X, and where T_max defines a maximum time valueof the time values received from other STAs, then:

T(X)=T_max, if T(X)<T_max  Equation 1

In some cases, setting the current time value of a clock signal of a STA106 according to Equation 1, may result in setting the time value to anerroneous value that may disrupt the discovery packet transmissioncycle. For example, STA Y may have a fast clock and may not update itsclock as the clocks of other devices are of a lesser value than its ownclock. Furthermore, STA A may not have transmitted a discovery packetwith its fast clock value for a long period of time (e.g., as comparedto average periods for transmitting a discovery packet with a clockvalue). In this case, when STA Y transmits a message with its fast clockvalue, the value may be far ahead of the current value of a receivingSTA Z and the discovery packet transmission cycle may be disrupted withSTA Z, for example, missing the discovery interval 302 a. As such, itmay be desirable to use different methods for synchronizing STAs in apeer-to-peer network.

According to some embodiments, rather than immediately setting thecurrent time value to the maximum of the received time values, the STA106 may perform some analysis of the received time values. For example,if the maximum time is significantly ahead and of the current time valueof the STA 106, the STA 106 may either not adjust its current time valueor make some other adjustment according to other data derived from theone or more received messages, or the STA 106 may wait for furthermessages before updating.

FIG. 5 is a flowchart of a method 500 of synchronizing a wirelesscommunications device, in accordance with an embodiment. Although themethod 500 is described below with respect to the elements of thewireless device 202, those having ordinary skill in the art willappreciate that other components may be used to implement one or more ofthe blocks described herein. At block 502, one or more messages may bereceived including one or more received time values. For example areceiver 212 of a STA 106 may receive one or more messages includingreceived time values from other STAs in the network. At block 504, amaximum time value of at least a portion of the received time values maybe determined. For example, a processor 204 determines the maximum timevalue that may correspond to the time value that is the farthest aheadin time of at least some portion of the received time values. At block506, a current time value is updated to a value derived from thereceived time values if a magnitude of the difference between thecurrent time value and the maximum received time value is greater than athreshold. Stated another way, the processor 204 may update the timevalue to a value derived from the one or more received time values inresponse to determining that a magnitude of the difference between thecurrent time value of that STA 106 and the maximum received time valueis greater than a threshold. For example, the processor 204 may updatethe current time value (e.g., of a clock 224) to the derived time valueif the magnitude of the difference as compared to the maximum receivedtime value is greater than a threshold. In some embodiments, the valuemay correspond to different methods for comparing the current time valuewith the maximum time value. The derived time value may be determined ina variety of ways. For example, the derived time value may be themaximum received time value as determined in block 504. Furthermore, thederived time value may correspond to the average of the received timevalues.

For example, where T(X) defines the time value of a clock signal of aSTA X, and where T_max defines a maximum time value of the time valuesreceived from other STAs, then:

T(X)=T_max, if |T(X)−T_max|>Threshold  Equation 2

As such, in Equation 2, T_max may be the derived time value. Thethreshold may correspond to, for example a value that may result indisturbing the discovery process. It should be appreciated that othercomparisons may be used to determine when to set the current time valueto the maximum received time value.

FIG. 6 is a functional block diagram of an exemplary wirelesscommunication device 600 that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B. The wireless device 600 mayinclude a receiving module 602. The receiving module 602 may thereceiver 212, transceiver 214, and/or memory 206. In one aspect, meansfor receiving may include the receiving module 602. The receiving module602 may be configured to perform one or more of the functions describedabove with respect to block 502 of FIG. 5. The wireless device 600 mayfurther include a determining module 604. The determining module 604 mayinclude the processor 204 and/or memory 206 of FIG. 2. In one aspect,means for determining may include the determining module 604. Thedetermining module 604 may be configured to perform one or more of thefunctions described above with respect to block 504 of FIG. 5. Thewireless device 600 may include an updating module 606. The updatingmodule 606 may further include a processor 204 as shown in FIG. 2. Inone aspect, means for updating may include the updating module 606. Theupdating module 606 may be configured to perform one or more of thefunctions described above with reference to block 506 of FIG. 5.

In addition to comparing the maximum received time value with thecurrent time value before updating, an amount of excessive drift may bedetermined to determine when to update. FIG. 7 is a flowchart of anothermethod 700 of synchronizing a wireless communications device, inaccordance with an embodiment. Although the method 700 is describedbelow with respect to the elements of the wireless device 202, thosehaving ordinary skill in the art will appreciate that other componentsmay be used to implement one or more of the blocks described herein.

As described above with reference to FIG. 5, blocks 702 and 704correspond to blocks 502 and 504 of FIG. 5. At block 706, an amount ofclock drift is determined based on the current time value of a STA 106as compared to the maximum received time value. For example, a processor204 may be configured to determine the amount of clock drift. At block708, the current time value is updated to a value derived from the oneor more received time values if a magnitude of the difference betweenthe current time value and the maximum received time value is greaterthan a threshold (as described above with reference to FIGS. 5-6) andthe clock drift is less than a threshold. The drift may be determinedwith respect to a time interval between the last time the clock signalwas updated and the current time. For example, according to anembodiment, where T(X) defines the time value of a clock signal of a STAX, where T_max defines a maximum time value of the time values receivedfrom other STAs, and where T_(interval) defines the interval between thelast time the clock was updated and the current time then:

$\begin{matrix}{{{T(X)} = T_{\max}},{{{if}\mspace{14mu} {{{T(X)} - {T\_ max}}}} > {{Threshold}\mspace{14mu} {and}\mspace{14mu} \frac{{{T(X)} - {T\_ max}}}{T_{interval}}} < {{Drift}\mspace{14mu} {Threshold}}}} & {{Equation}\mspace{14mu} 3}\end{matrix}$

It should be appreciated that T(X) may be set to some value derived fromthe one or more received time values in Equation three, as describedabove with reference to FIG. 5. In this way, the STA 106 may detect, forexample if the clock drifts by more than 1 or 2% that there is a rogueclock value and the STA 106 should wait to update the current clockvalue or use some other time value for the update. Stated another way,in addition to the conditions described above with reference to FIG. 5,updating may be further in response to determining that a ratio of thedifference between the maximum time value and the current time value tosome drift time interval is less than a threshold.

FIG. 8 is a functional block diagram of an exemplary wirelesscommunication device 800 that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B. The wireless device 800 mayinclude a receiving module 802. The receiving module 802 may thereceiver 212, transceiver 214, and/or memory 206. In one aspect, meansfor receiving may include the receiving module 802. The receiving module802 may be configured to perform one or more of the functions describedabove with respect to block 702 of FIG. 7. The wireless device 800 mayfurther include a determining module 804. The determining module 804 mayinclude the processor 204 and/or memory 206 of FIG. 2. In one aspect,means for determining may include the determining module 804. Thedetermining module 804 may be configured to perform one or more of thefunctions described above with respect to block 704 of FIG. 7. Thewireless device 800 may include a drift determining module 808. In oneaspect, the drift determining module 808 may include the processor 204of FIG. 2. In one aspect, a means for determining drift may include thedrift determining module. The drift determining module may be configuredto perform one or more of the functions described above with referenceto block 706 of FIG. 7. The wireless device 800 may include an updatingmodule 806. The updating module 806 may further include a processor 204as shown in FIG. 2. In one aspect, means for updating may include theupdating module 806. The updating module 806 may be configured toperform one or more of the functions described above with reference toblock 708 of FIG. 7.

In further embodiments, before determining the maximum time value, theSTA 106 may filter the received time values to detect erroneous orotherwise less accurate time values. The filtered out time values maycorrespond to time values that, if used by the STA 106, would disrupt adiscovery process, for example. For example, as described above, themaximum time value may be determined from just a portion of the one ormore received time values, where the portion corresponds to time valuesnot filtered out.

FIG. 9 is a flowchart of another method of synchronizing a wirelesscommunications device, in accordance with an embodiment. Although themethod 900 is described below with respect to the elements of thewireless device 202, those having ordinary skill in the art willappreciate that other components may be used to implement one or more ofthe blocks described herein.

At block 902, the STA 106 may receive one or more messages including oneor more received time values of other STAs in the network. At block 904,one or more of the received time values is filtered out. For example,the filtered out time values may correspond to time values whose driftas compared to the current time value is greater than a threshold. Aprocessor 204 may be configured to filter the time values. At block 906,a maximum time value of the filtered received time values is determined.A processor 204 may further determine the maximum received time value.At block 908, a current time value is updated to a value derived fromthe received time values if a magnitude of the difference between thecurrent time value and the maximum received time value is greater than athreshold. The derived value may correspond to the values describedabove with reference to FIG. 5. In some aspects, the current time valuemay be compared to the derived value, such as determining a magnitude ofthe difference between the current time value and the derived timevalue.

As an example, the STA 106 may filter out time values that haveexcessive drift. For example, according to an embodiment, where T(X)defines the time value of a clock signal of a STA X, where T_(interval)defines the interval between the last time the clock was updated and thecurrent time, and where T(i), i=1 . . . N defines clock values ofdevices that have been received then:

$\begin{matrix}{{T\_ max} = {{maximum}\mspace{14mu} \left( {{T(X)},{{{T(i)}\mspace{14mu} {for}\mspace{14mu} {all}\mspace{14mu} i} = {1\mspace{14mu} \ldots \mspace{14mu} N}},{{{such}\mspace{14mu} {that}\mspace{14mu} \frac{{{T(X)} - {T(i)}}}{T_{interval}}} < {{Drift}\mspace{14mu} {Threshold}}}} \right.}} & {{Equation}\mspace{14mu} 4}\end{matrix}$

The drift threshold may be based on a maximum allowed clock drifttolerance that may be dynamically determined or predetermined. As such,T_max is the maximum of only those received time values that have notdrifted as compared to the current time value more than a certainamount. Using the new filtered value of T_max:

T(X)=T_max, if |T(X)−T_max|>Threshold  Equation5

It should be appreciated that T(X) may be set to a value derived fromthe received time values according to Equation 5 as described above withreference to FIG. 5. Filtering may further be accomplished in otherways. For example, as is further described below, the received timevalues from other STAs may be received along with information relatingto the accuracy of the received time values. Some value may betransmitted that might indicate the confidence or accuracy of the timevalue. For example, if the received time value corresponds to a STA 106that has not updated its time value for a significant amount of time,the received time value may be received information indicating that thereceived time value is not as accurate. In one aspect, GPS informationmay be included. This information may be used to rank or prioritize thereceived time values according to predicted accuracy. As such, filteringmay take this information into account.

FIG. 10 is a flowchart of another method of synchronizing a wirelesscommunications device, in accordance with an embodiment. Although themethod 1000 is described below with respect to the elements of thewireless device 202, those having ordinary skill in the art willappreciate that other components may be used to implement one or more ofthe blocks described herein. At block 1002, a STA 106 receives one ormore messages including one or more received time values and informationabout the one or more received time values. At block 1004, one or moreof the received time values may be filtered out based on the informationreceived about the one or more time values. As described above theinformation may relate to the accuracy or confidence that the receivedtime value could be used to update a current time value of the STA 106.AT block 1006, a maximum time value is determined of the filteredreceived time values. At block 1008, the current time value is updatedto a value derived from the received time values if a magnitude of thedifference between the current time value and the maximum received timevalue is greater than a threshold.

In addition, filtering may be done using statistical analysis of thereceived time intervals. For example, the received time intervals may bemapped into a histogram or other similar construct. The histogram orother statistical construct may then be analyzed by the processor 204 tofilter out different time intervals based on some criteria. For example,those received values that are further than one or two standarddeviations, for example, from a mean of the received time values may notbe used in the update process. Other statistical analysis is furthercontemplated to filter the time values.

FIG. 11 is a functional block diagram of an exemplary wirelesscommunication device 1100 that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B. The wireless device 1100 mayinclude a receiving module 1102. The receiving module 1102 may thereceiver 212, transceiver 214, and/or memory 206. In one aspect, meansfor receiving may include the receiving module 1102. The receivingmodule 1102 may be configured to perform one or more of the functionsdescribed above with respect to blocks 902 or 1002 of FIGS. 9 and 10.The wireless device 1100 may further include a filtering module 1108. Aprocessor 204 and memory may be included in the filtering module 1108.In one aspect, means for filtering may include the filtering module1108. The filtering module 1108 may be configured to perform one or moreof the functions described with reference to blocks 904 or 1004 of FIGS.9 and 10. The wireless device 1100 may further include a determiningmodule 1104. The determining module 1104 may include the processor 204and/or memory 206 of FIG. 2. In one aspect, means for determining mayinclude the determining module 1104. The determining module 1104 may beconfigured to perform one or more of the functions described above withrespect to blocks 906 or 1006 of FIGS. 9 and 10. The wireless device1100 may include an updating module 1106. The updating module 1106 mayfurther include a processor 204 as shown in FIG. 2. In one aspect, meansfor updating may include the updating module 1106. The updating module1106 may be configured to perform one or more of the functions describedabove with reference to blocks 908 or 1008 of FIGS. 9 and 10.

In addition to further analysis of received time values, a STA 106 mayfurther take certain actions when transmitting time values to aid insynchronization. For example, the STA 106 may be configured to transmitits time value only if certain conditions are met, or may wish totransmit information relating to the accuracy of the time intervaltransmitted by the STA 106. FIG. 12 is a flowchart of another method ofsynchronizing a wireless communications device, in accordance with anembodiment. Although the method 1200 is described below with respect tothe elements of the wireless device 202, those having ordinary skill inthe art will appreciate that other components may be used to implementone or more of the blocks described herein.

At block 1202, a first time interval since last transmitting a messageincluding a current time value is determined. This may correspond to aSTA 106 that has not sent out its time information for a significantamount of time (e.g., one hundred seconds). At block 1204, a second timeinterval since updating the current time value may be determined. Forexample, this may correspond to a STA 106 that has not updated its timevalue for a significant amount of time (e.g., because the STA 106 wassleeping and more clock drift may occur). At block 1206, a message maybe transmitted that is based on comparing the first time interval to afirst threshold and comparing the second time interval to a secondthreshold.

For example, in one embodiment, the STA 106 may not include its ownclock in a discovery packet if it has not sent out its time informationaccording to some threshold or if it has not updated its time based onother received time intervals. In another embodiment, the STA 106 mightsend information relating to the accuracy of the time interval thatmight indicate how accurate the time interval is for purposes ofsynchronization. For example, in one embodiment, a STA 106 may include abit in the discovery packet that indicates that the clock timetransmitted may not be used for synchronization purposes.

FIG. 13 illustrates a message 1300 that may include a time value 1310for synchronization. The message 1300 may correspond to a discoverypacket in some implementations. The message 1300 may include headerinformation 1308. The message 1300 may include a time value 1310corresponding to a current time value of a clock signal (e.g., atimestamp). In addition the message 1300 may include time valueinformation 1310 that may relate to the accuracy of the time value orhow it might be used in synchronization. The message 1300 may furtherinclude discovery packet data 1312.

FIG. 14 is a functional block diagram of an exemplary wirelesscommunication device that may be employed with the wirelesscommunication system of FIG. 1A or FIG. 1B. The wireless device 1400 mayinclude a determining module 1404. In one aspect, the determining module1404 may include a processor. In one aspect, means for determining mayinclude the determining module 1404. The determining module 1404 may beconfigured to perform one or more of the functions described above withreference to blocks 1202 and 1204 of FIG. 12. The wireless device 1400may include a transmitting module 1402. The receiving module 1402 maythe transmitter 210, transceiver 214, and/or memory 206. In one aspect,means for transmitting may include the transmitting module 1402. Thereceiving module 1402 may be configured to perform one or more of thefunctions described above with respect to block 1206 of FIG. 12.

FIG. 15 is a plot showing exemplary values for how much time may beneeded to join a NAN network based on different sync frameprobabilities. For example, as a non-limiting example, there may befifty STAs in the NAN spread out in a 400×400 area. As one example, eachSTA 106 may have a transmission range of 80 meters (e.g., for examplebased on mobile transmit power 18 dBm with a 5 dB noise figure for onechannel model ad 8 dB additional pathloss. In this scenario, fifty newdevices may want to join and they each need to hear at least one syncframe. FIG. 15 shows exemplary times for joining the network for threedifferent exemplary P_sync values, 1.0, 0.5, and 0.2. As shown, evenwith P_sync equal to 0.2, in an exemplary case over ninety percent ofthe new devices obtain a sync frame within five discovery periods.

It should be understood that any reference to an element herein using adesignation such as “first,” “second,” and so forth does not generallylimit the quantity or order of those elements. Rather, thesedesignations may be used herein as a convenient method of distinguishingbetween two or more elements or instances of an element. Thus, areference to first and second elements does not mean that only twoelements may be employed there or that the first element must precedethe second element in some manner. Also, unless stated otherwise a setof elements may include one or more elements.

A person/one having ordinary skill in the art would understand thatinformation and signals may be represented using any of a variety ofdifferent technologies and techniques. For example, data, instructions,commands, information, signals, bits, symbols, and chips that may bereferenced throughout the above description may be represented byvoltages, currents, electromagnetic waves, magnetic fields or particles,optical fields or particles, or any combination thereof.

A person/one having ordinary skill in the art would further appreciatethat any of the various illustrative logical blocks, modules,processors, means, circuits, and algorithm steps described in connectionwith the aspects disclosed herein may be implemented as electronichardware (e.g., a digital implementation, an analog implementation, or acombination of the two, which may be designed using source coding orsome other technique), various forms of program or design codeincorporating instructions (which may be referred to herein, forconvenience, as “software” or a “software module), or combinations ofboth. To clearly illustrate this interchangeability of hardware andsoftware, various illustrative components, blocks, modules, circuits,and steps have been described above generally in terms of theirfunctionality. Whether such functionality is implemented as hardware orsoftware depends upon the particular application and design constraintsimposed on the overall system. Skilled artisans may implement thedescribed functionality in varying ways for each particular application,but such implementation decisions should not be interpreted as causing adeparture from the scope of the present disclosure.

The various illustrative logical blocks, modules, and circuits describedin connection with the aspects disclosed herein and in connection withFIGS. 1-11 may be implemented within or performed by an integratedcircuit (IC), an access terminal, or an access point. The IC may includea general purpose processor, a digital signal processor (DSP), anapplication specific integrated circuit (ASIC), a field programmablegate array (FPGA) or other programmable logic device, discrete gate ortransistor logic, discrete hardware components, electrical components,optical components, mechanical components, or any combination thereofdesigned to perform the functions described herein, and may executecodes or instructions that reside within the IC, outside of the IC, orboth. The logical blocks, modules, and circuits may include antennasand/or transceivers to communicate with various components within thenetwork or within the device. A general purpose processor may be amicroprocessor, but in the alternative, the processor may be anyconventional processor, controller, microcontroller, or state machine. Aprocessor may also be implemented as a combination of computing devices,e.g., a combination of a DSP and a microprocessor, a plurality ofmicroprocessors, one or more microprocessors in conjunction with a DSPcore, or any other such configuration. The functionality of the modulesmay be implemented in some other manner as taught herein. Thefunctionality described herein (e.g., with regard to one or more of theaccompanying figures) may correspond in some aspects to similarlydesignated “means for” functionality in the appended claims.

If implemented in software, the functions may be stored on ortransmitted over as one or more instructions or code on acomputer-readable medium. The steps of a method or algorithm disclosedherein may be implemented in a processor-executable software modulewhich may reside on a computer-readable medium. Computer-readable mediaincludes both computer storage media and communication media includingany medium that can be enabled to transfer a computer program from oneplace to another. A storage media may be any available media that may beaccessed by a computer. By way of example, and not limitation, suchcomputer-readable media may include RAM, ROM, EEPROM, CD-ROM or otheroptical disk storage, magnetic disk storage or other magnetic storagedevices, or any other medium that may be used to store desired programcode in the form of instructions or data structures and that may beaccessed by a computer. Also, any connection can be properly termed acomputer-readable medium. Disk and disc, as used herein, includescompact disc (CD), laser disc, optical disc, digital versatile disc(DVD), floppy disk, and blu-ray disc where disks usually reproduce datamagnetically, while discs reproduce data optically with lasers.Combinations of the above should also be included within the scope ofcomputer-readable media. Additionally, the operations of a method oralgorithm may reside as one or any combination or set of codes andinstructions on a machine readable medium and computer-readable medium,which may be incorporated into a computer program product.

It is understood that any specific order or hierarchy of steps in anydisclosed process is an example of a sample approach. Based upon designpreferences, it is understood that the specific order or hierarchy ofsteps in the processes may be rearranged while remaining within thescope of the present disclosure. The accompanying method claims presentelements of the various steps in a sample order, and are not meant to belimited to the specific order or hierarchy presented.

Various modifications to the implementations described in thisdisclosure may be readily apparent to those skilled in the art, and thegeneric principles defined herein may be applied to otherimplementations without departing from the spirit or scope of thisdisclosure. Thus, the disclosure is not intended to be limited to theimplementations shown herein, but is to be accorded the widest scopeconsistent with the claims, the principles and the novel featuresdisclosed herein. The word “exemplary” is used exclusively herein tomean “serving as an example, instance, or illustration.” Anyimplementation described herein as “exemplary” is not necessarily to beconstrued as preferred or advantageous over other implementations.

Certain features that are described in this specification in the contextof separate implementations also can be implemented in combination in asingle implementation. Conversely, various features that are describedin the context of a single implementation also can be implemented inmultiple implementations separately or in any suitable sub-combination.Moreover, although features may be described above as acting in certaincombinations and even initially claimed as such, one or more featuresfrom a claimed combination can in some cases be excised from thecombination, and the claimed combination may be directed to asub-combination or variation of a sub-combination.

Similarly, while operations are depicted in the drawings in a particularorder, this should not be understood as requiring that such operationsbe performed in the particular order shown or in sequential order, orthat all illustrated operations be performed, to achieve desirableresults. In certain circumstances, multitasking and parallel processingmay be advantageous. Moreover, the separation of various systemcomponents in the implementations described above should not beunderstood as requiring such separation in all implementations, and itshould be understood that the described program components and systemscan generally be integrated together in a single software product orpackaged into multiple software products. Additionally, otherimplementations are within the scope of the following claims. In somecases, the actions recited in the claims can be performed in a differentorder and still achieve desirable results.

What is claimed is:
 1. A method of wireless communications, the methodcomprising: determining, at a wireless communication apparatus, a firsttime interval since transmitting a message including a time value of aclock signal of the wireless communication apparatus; determining, atthe wireless communication apparatus, a second time interval sinceupdating the time value of the wireless communication apparatus; andtransmitting a message comprising content that is based on comparing thefirst time interval to a first threshold and comparing the second timeinterval to a second threshold.
 2. The method of claim 1, furthercomprising: receiving, at the wireless communication apparatus, awireless message; and updating the time value based on the receivedwireless message.
 3. The method of claim 1, further comprising: updatingthe time value; and entering a sleep state after updating the timevalue, wherein the time value is not updated in the sleep state, andwherein the determining is performed after leaving the sleep state. 4.The method of claim 1, further comprising: determining the time valueshould not be used for synchronization purposes in response to thesecond time interval exceeding the second threshold; and excluding thetime value of the wireless communication apparatus from the content inresponse to the determining.
 5. The method of claim 1, furthercomprising excluding the time value of the wireless communicationapparatus from the content in response to the first time interval beingbelow the first threshold.
 6. The method of claim 1, further comprisingincluding the time value and information indicating whether the timevalue is used for synchronization purposes in the content.
 7. The methodof claim 1, further comprising including the time value and informationindicating an accuracy level of the time value in the content.
 8. Awireless apparatus operable in a wireless communication systemcomprising: a processor configured to: determine a first time intervalsince transmitting a message including a time value of a clock signal ofthe wireless communication apparatus; and determine a second timeinterval since updating the time value of the wireless communicationapparatus; and a transmitter configured to transmit a message comprisingcontent that is based on comparing the first time interval to a firstthreshold and comparing the second time interval to a second threshold.9. The wireless apparatus of claim 8, wherein the processor is furtherconfigured to: receive a wireless message; and update the time valuebased on the received wireless message.
 10. The wireless apparatus ofclaim 8, wherein the processor is further configured to: update the timevalue; and enter a sleep state after updating the time value, whereinthe determining is performed after leaving the sleep state
 11. Thewireless apparatus of claim 8, wherein the processor is furtherconfigured to: determine the time value should not be used forsynchronization purposes in response to the second time intervalexceeding the second threshold; and exclude the time value of thewireless communication apparatus from the content in response to thedetermining.
 12. The wireless apparatus of claim 8, wherein theprocessor is further configured to exclude the time value of thewireless communication apparatus from the content in response to thefirst time interval being below the first threshold.
 13. The wirelessapparatus of claim 8, wherein the processor is further configured toinclude the time value and information indicating whether the time valueis used for synchronization purposes in the content.
 14. The wirelessapparatus of claim 8, wherein the processor is further configured toinclude the time value and information indicating an accuracy level ofthe time value in the content.
 15. A computer program product,comprising: a computer readable medium comprising: code for determininga first time interval since transmitting a message including a timevalue of a clock signal of the wireless communication apparatus; codefor determining a second time interval since updating the time value ofthe wireless communication apparatus; and code for transmitting amessage comprising content that is based on comparing the first timeinterval to a first threshold and comparing the second time interval toa second threshold.
 16. The computer program product of claim 15,wherein the computer readable medium further comprises: code forupdating the time value; and code entering a sleep state after updatingthe time value, wherein the determining is performed after leaving thesleep state
 17. The computer program product of claim 15, wherein thecomputer readable medium further comprises: code for determining thetime value should not be used for synchronization purposes in responseto the second time interval exceeding the second threshold; and code forexcluding the time value of the wireless communication apparatus fromthe content in response to the determining.
 18. The computer programproduct of claim 15, wherein the computer readable medium furthercomprises code for excluding the time value of the wirelesscommunication apparatus from the content in response to the first timeinterval being below the first threshold.
 19. The computer programproduct of claim 15, wherein the computer readable medium furthercomprises code for including the time value and information indicatingwhether the time value is used for synchronization purposes in thecontent.
 20. The computer program product of claim 15, wherein thecomputer readable medium further comprises code for including the timevalue and information indicating an accuracy level of the time value inthe content.